<?php
	class Mhome extends CI_Model{
		protected $_co = "cocau";
		protected $_sv = "service";
		protected $_pro = "project";
		public function __construct(){
			parent::__construct();
			$this->load->database();
		}
		public function cocau($id=1){
			$this->db->where("co_id",$id);
			return $this->db->get($this->_co)->row_array();
		}
		public function update_cc($body,$id){
			$this->db->where("co_id",$id);
			$this->db->update($this->_co,$body);
		}
		public function service($id=1){
			$this->db->where("sv_id",$id);
			return $this->db->get($this->_sv)->row_array();
		}
		public function update_sv($body,$id){
			$this->db->where("sv_id",$id);
			$this->db->update($this->_sv,$body);
		}
		public function project($id=1){
			$this->db->where("pro_id",$id);
			return $this->db->get($this->_pro)->row_array();
		}
		public function update_pro($body,$id){
			$this->db->where("pro_id",$id);
			$this->db->update($this->_pro,$body);
		}
	}